#include "androiddialog.h"
#include "ui_androiddialog.h"
#include <QMessageBox>

AndroidDialog::AndroidDialog(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::AndroidDialog)
{
    ui->setupUi(this);
    isRed = false;
}

AndroidDialog::~AndroidDialog()
{
    delete ui;
}

void AndroidDialog::on_pushButton_clicked()
{
    if (!isRed){
       ui->label->setStyleSheet("color:red");
       isRed = true;
    }else{
        ui->label->setStyleSheet("color:black");
        isRed = false;
    }
    QMessageBox::information(this, "Color", QString("Current Color: %1")
                             .arg(isRed? "Red" : "Black"), QMessageBox::Ok);
}
